package common;

public class ChatPacket implements Sendable {

	private static final long serialVersionUID = -4768792849414331208L;
	private static final int length = 75;
	
	public final String from;
	public final String msg;
	
	public ChatPacket(String name, String msg) {
		from=name;
		this.msg = msg;
	}
	
	public String getType() {
		return "ChatPacket";
	}
	public String toString() { 
		return from + " : " + msg;
	}
	public boolean isValid() {
		return msg.length() <= length;
	}

}
